<template>
  <el-table
    :data="genTableColumnState.tableList"
    style="width: 100%">
          <el-table-column prop="tableId" label="归属表编号"></el-table-column>
          <el-table-column prop="columnName" label="列名称"></el-table-column>
          <el-table-column prop="columnComment" label="列描述"></el-table-column>
          <el-table-column prop="columnType" label="列类型"></el-table-column>
          <el-table-column prop="javaType" label="JAVA类型"></el-table-column>
          <el-table-column prop="javaField" label="JAVA字段名"></el-table-column>
          <el-table-column prop="isPk" label="是否主键（1是）">
            <template slot-scope="scope">
              <el-link v-if="scope.row.isPk === 0" >无效</el-link>
              <span v-else>正常</span>
            </template>
          </el-table-column>
          <el-table-column prop="isIncrement" label="是否自增（1是）">
            <template slot-scope="scope">
              <el-link v-if="scope.row.isIncrement === 0" >无效</el-link>
              <span v-else>正常</span>
            </template>
          </el-table-column>
          <el-table-column prop="isRequired" label="是否必填（1是）">
            <template slot-scope="scope">
              <el-link v-if="scope.row.isRequired === 0" >无效</el-link>
              <span v-else>正常</span>
            </template>
          </el-table-column>
          <el-table-column prop="isInsert" label="是否为插入字段（1是）">
            <template slot-scope="scope">
              <el-link v-if="scope.row.isInsert === 0" >无效</el-link>
              <span v-else>正常</span>
            </template>
          </el-table-column>
          <el-table-column prop="isEdit" label="是否编辑字段（1是）">
            <template slot-scope="scope">
              <el-link v-if="scope.row.isEdit === 0" >无效</el-link>
              <span v-else>正常</span>
            </template>
          </el-table-column>
          <el-table-column prop="isList" label="是否列表字段（1是）">
            <template slot-scope="scope">
              <el-link v-if="scope.row.isList === 0" >无效</el-link>
              <span v-else>正常</span>
            </template>
          </el-table-column>
          <el-table-column prop="isQuery" label="是否查询字段（1是）">
            <template slot-scope="scope">
              <el-link v-if="scope.row.isQuery === 0" >无效</el-link>
              <span v-else>正常</span>
            </template>
          </el-table-column>
          <el-table-column prop="queryType" label="查询方式（等于、不等于、大于、小于、范围）"></el-table-column>
          <el-table-column prop="htmlType" label="显示类型（文本框、文本域、下拉框、复选框、单选框、日期控件）"></el-table-column>
          <el-table-column prop="dictType" label="字典类型"></el-table-column>
          <el-table-column prop="sort" label="排序"></el-table-column>
          <el-table-column prop="createBy" label="创建者"></el-table-column>
          <el-table-column prop="updateBy" label="更新者"></el-table-column>
          <el-table-column prop="updateTime" label="更新时间">
            <template slot-scope="scope">
              <div>
                {{plugins.changeDate(scope.row.updateTime, "yymmddhhmmss")}}
              </div>
            </template>
          </el-table-column>
  </el-table>
</template>

<script>
import { mapState } from "vuex";
export default {
  computed: {
    ...mapState({
      rootState: state => state,
      genTableColumnState: state => state.GenTableColumn
    }),
  },
  data() {
    return {
    }
  }
}
</script>

<style scoped>

</style>
